<table width='100%' id='creTab'></table>


<STYLE type="text/css">
.textArea{
	color: red;
    font-family: Verdana,Arial,Sans-serif;
    font-size: 0.8em;
}

span{
	color: green;
    font-family: Verdana,Arial,Sans-serif;
    font-size: 0.8em;
}

</style>


<script language='javascript'>

	function alertMe(){
		alert("this : "+this + " / Value = "+ this.value);

	}

	function alertCheckedMe(){
		alert("Value = "+ this.value+" / selected = "+ this.checked);
	}
	
	function addListener(element, type, fn, bubbling){
		if(window.addEventListener)	{ // Standard
			element.addEventListener(type, fn, bubbling);
		} 
		else if(window.attachEvent) { // IE
			element.attachEvent('on'+type , fn);
		} 
	}


	var creTab = document.getElementById('creTab');
	creTab.border='1';

	function getRowCount(){
		return creTab.rows.length;
	}
	
	
	var row1 = creTab.insertRow(getRowCount());
	row1.align='center';
		
		var r1c1 = row1.insertCell(0);
		r1c1.width='17%';
		r1c1.height='100';
			var r1c0el = document.createElement('input');
			r1c0el.type = 'text';
			r1c0el.name = 'txtEle';
			r1c0el.id = 'txtEleId';
			r1c0el.value = '';
			r1c0el.size = 10;
			r1c0el.maxLength = 6;					
			addListener(r1c0el, 'keypress', alertMe, false);
			//r1c0el.attachEvent('onKeyPress' , alertMe);
		r1c1.appendChild(r1c0el);


		var r1c1 = row1.insertCell(1);
		r1c1.width='17%';
			var r1c1el = document.createElement('input');
			r1c1el.type = 'checkbox';
			r1c1el.name = 'chkEle';
			r1c1el.value = 'r1c1el';
			r1c1el.defaultChecked = true; // in IE r1c1el.checked = true; is not working 
			addListener(r1c1el, 'click', alertCheckedMe, false);
		r1c1.appendChild(r1c1el);	
			var r1c1e2 = document.createElement('input');
			r1c1e2.type = 'checkbox';
			r1c1e2.name = 'chkEle';
			r1c1e2.value = 'r1c1e2';
			r1c1e2.defaultChecked = false; // in IE r1c1el.checked = true; is not working 
			addListener(r1c1e2, 'click', alertCheckedMe, false);
		r1c1.appendChild(r1c1e2);
			var r1c1e3 = document.createElement('input');
			r1c1e3.type = 'checkbox';
			r1c1e3.name = 'chkEle';
			r1c1e3.value = 'r1c1e3';
			r1c1e3.defaultChecked = true; // in IE r1c1el.checked = true; is not working 
			addListener(r1c1e3, 'click', alertCheckedMe, false);
		r1c1.appendChild(r1c1e3);	
		

		var r1c2 = row1.insertCell(2);
		r1c2.width='17%';
			var r1c2el = document.createElement('select');
			r1c2el.name = 'selEle';
			r1c2el.options[r1c2el.length] = new Option('--Select--', 'none');
			r1c2el.options[r1c2el.length] = new Option('text zero', 'value0');
			r1c2el.options[1].selected = true;
			r1c2el.options[r1c2el.length] = new Option('text one', 'value1');
			//r1c2el.class = 6;
		r1c2.appendChild(r1c2el);


		var r1c3 = row1.insertCell(3);
		r1c3.width='17%';
			var r1c3e1 = document.createElement('textarea');
			r1c3e1.name = 'txtAreaEle';
			r1c3e1.rows = 3;
			r1c3e1.cols = 20;
			//r1c3e1.maxLength = 6;
			//r1c0el.class = 6;
		r1c3.appendChild(r1c3e1);


		var r1c4 = row1.insertCell(4);
		r1c4.width='17%';
			var r1c4e1 = document.createElement('input');
			r1c4e1.type = 'radio';
			r1c4e1.name = 'radioEle';
			//r1c4e1.defaultChecked = true;
		r1c4.appendChild(r1c4e1);	
			var r1c4e2 = document.createElement('input');
			r1c4e2.type = 'radio';
			r1c4e2.name = 'radioEle';
			r1c4e2.defaultChecked = true; // defaultChecked is done for radio and checkbox. IE validation
		r1c4.appendChild(r1c4e2);	
			var r1c4e3 = document.createElement('input');
			r1c4e3.type = 'radio';
			r1c4e3.name = 'radioEle';
			//r1c4e3.defaultChecked = true;
		r1c4.appendChild(r1c4e3);	



		var r1c5 = row1.insertCell(5);
		r1c5.width='15%';
		r1c5.rowspan='2';
		var r1c5e1 = document.createTextNode('Virtialar Information');
		r1c5.appendChild(r1c5e1);
		r1c5.className = 'textArea';


	



		


	
	


	

	

	
</script>